package com.insigma.business.qrcode.soldier.dto;


import com.insigma.business.qrcode.common.vo.DescEnum;

import java.util.LinkedHashMap;
import java.util.Map;


public enum ThroughTrainTypeEnum implements DescEnum {


    
    SXDW("双选单位直通车"),

    
    QT("其他单位直通车"),

    
    SGAJ("公安司法系统直通车"),






    
    ZY("专业直通车"),

    
    SYDW("事业单位直通车"),

    
    YDG("一等功直通车"),

    
    QY("企业直通车"),

    
    GJZCGB("高级职称干部直通车");

    
    private String desc;

    ThroughTrainTypeEnum(String desc) {
        this.desc = desc;
    }

    
    public static ThroughTrainTypeEnum getByEnumName(final String enumName) {
        for (ThroughTrainTypeEnum element : values()) {
            if (element.name().equals(enumName)) {
                return element;
            }
        }
        return null;
    }

    
    public static Map<String, String> getName2TitleMap() {

        final Map<String, String> name2TitleMap = new LinkedHashMap<>();

        for (ThroughTrainTypeEnum element : values()) {
            name2TitleMap.put(element.name(), element.desc);
        }

        return name2TitleMap;
    }

    @Override
    public String getDesc() {
        return this.desc;
    }
}
